import {
    INCREMENTCOUNT,
    DECREMENTCOUNT
} from '../constant/countConst'
import store from '../store'
export const incrementAction=(data=1)=>{
   return {
    type: INCREMENTCOUNT,
    data
   }
}
export const decrementAction=(data=1)=>{
    return {
     type: DECREMENTCOUNT,
     data
    }
 }
 export const waitIncrementAction = (data)=>{
    return () =>{
        setTimeout(()=>{
         store.dispatch({
            type: INCREMENTCOUNT,
            data
         })   
        })
      
    }
 }
